<extend name="Base:common" />
<block name="static">
<script src="__PUBLIC__/js/jquery-1.8.3.min.js"></script>

<style type="text/css">
  #pageflip{right:0px;position:fixed;top:0px;z-index: 1;}
  #pageflip img{z-index: 1;right: 0px;width: 50px;position: absolute;top: 0px;height: 52px;ms-interpolation-mode: bicubic;}
  .msg_block{right:0px;width:50px;position:absolute;overflow:hidden;top:0px;background:url(/templates/default/images/sijiao/page_flip.png) no-repeat right top;height:50px}
  .yNavIndex .yMenuIndex .look_index_nav{position: relative;width: 120px;padding: 0px 40px 0px 0px;}
  .yNavIndex .yMenuIndex .look_index_nav a.look_index_nava{color:#ec610c;position:relative;}
  .yNavIndex .yMenuIndex .look_index_nav:hover a.look_index_nava{display: block; margin-top:-6px; margin-left:-5px; padding: 5px 0px 5px 15px; overflow: hidden; background-color: #fff; border: 1px solid #ddd; border-bottom: 0; box-shadow: 0 2px 4px #ccc; width: 138px;}
  .yNavIndex .yMenuIndex .look_index_nav a.look_index_nava:hover{font-weight: normal;}
  .yNavIndex .yMenuIndex .look_index_nav dl {position: absolute; z-index: 10; width: 162x; left: -5px; background: #fff; border: 1px solid #ddd; box-shadow: 0 2px 4px #ccc;border-top: 0; padding: 10px 0 10px 0;top: 33px;display:none;}
    .yNavIndex .yMenuIndex .look_index_nav dl dd a{color: #8d8d8d;display:block;padding-right:0px;width:142px;}
     .yNavIndex .yMenuIndex .look_index_nav dl dd a:hover{border:0px;font-weight: normal;color:#666;background:#f3f3f3;}
     .yNavIndex .yMenuIndex .look_index_nav:hover dl{display:block;}

     .ico-dot {
    position: absolute;
    width: 6px;
    height: 6px;
    overflow: hidden;
    border-radius: 50%;
    background: #db3652;
    box-shadow: 0px 0px 0 rgba(219,54,82,0);
    -webkit-animation: breath 0.8s 3 ease-in-out;
    -moz-animation: breath 0.8s 3 ease-in-out;
    -o-animation: breath 0.8s 3 ease-in-out;
    -ms-animation: breath 0.8s 3 ease-in-out;
    animation: breath 0.8s 3 ease-in-out;
     top: 2px;
    left: 54px;
  }
  .yNavIndex .yMenuIndex .look_index_nav:hover a.look_index_nava .ico-dot{display:none;}
  @-webkit-keyframes breath{0%{box-shadow:0px 0px 0 rgba(219,54,82,0);}50%{box-shadow:0px 0px 5px rgba(219,54,82,1);}100%{box-shadow:0px 0px 0 rgba(219,54,82,0);}}@-moz-keyframes breath{0%{box-shadow:0px 0px 0 rgba(219,54,82,0);}50%{box-shadow:0px 0px 5px rgba(219,54,82,1);}100%{box-shadow:0px 0px 0 rgba(219,54,82,0);}}@-o-keyframes breath{0%{box-shadow:0px 0px 0 rgba(219,54,82,0);}50%{box-shadow:0px 0px 5px rgba(219,54,82,1);}100%{box-shadow:0px 0px 0 rgba(219,54,82,0);}}@-ms-keyframes breath{0%{box-shadow:0px 0px 0 rgba(219,54,82,0);}50%{box-shadow:0px 0px 5px rgba(219,54,82,1);}100%{box-shadow:0px 0px 0 rgba(219,54,82,0);}}@keyframes breath{0%{box-shadow:0px 0px 0 rgba(219,54,82,0);}50%{box-shadow:0px 0px 5px rgba(219,54,82,1);}100%{box-shadow:0px 0px 0 rgba(219,54,82,0);}}
</style>


<link rel="stylesheet" href="__CSS__/go/index2.css" />	

<style>  
 .g-snow-con {
position: relative;
top: 130px;
z-index: 1001;
margin-bottom: -30px;
}
.g-snow {
background:none;
height: 30px;
_width: 1211px;
_margin: 0 auto;
}
.g-snow2 {
background:none;
height: 30px;
_width: 1012px;
_margin: 0 auto;
display: none;
} 
    .d {
 
 top: 0px;
 margin-top: 0px;
 padding-top:0px;
 margin-right: auto;
 margin-bottom: 0;
 margin-left: auto;
 background-color:#ffffff;
 background-repeat: no-repeat;
 background-position: center top; 
} </style>






<script>
            function delheader(id) {
                var Cartlist = $.cookie('Cartlist');
                var info = $.evalJSON(Cartlist);
                var num = $("#sCartTotal2").html() - 1;
                var sum = $("#sCartTotalM").html();
                info['MoenyCount'] = sum - info[id]['money'] * info[id]['num'];

                delete info[id];
                //$.cookie('Cartlist','',{path:'/'});
                $.cookie('Cartlist', $.toJSON(info), {
                    expires: 30,
                    path: '/'
                });
                $("#sCartTotalM").html(info['MoenyCount']);
                $('#sCartTotal2').html(num);
                $('#sCartTotal').text(num);
                $('#btnMyCart em').text(num);
                $("#mycartcur" + id).remove();
            }
            $(function() {
                $(".h_1yyg").mouseover(function() {
                    $(".h_1yyg_eject").show();
                });
                $(".h_1yyg").mouseout(function() {
                    $(".h_1yyg_eject").hide();
                });
                $(".h_news").mouseover(function() {
                    $(".h_news_down").show();
                });
                $(".h_news").mouseout(function() {
                    $(".h_news_down").hide();
                });
            });
</script>
</block>																											
<block name="body">			


    <script>
        $(document).ready(function(){
                $("#divGoodsSortList").hover(function() {
                $(this).addClass("U-goods-hover").children("div.U-goods-class").show().prev().find("b").addClass("b_Triangle")
                }
                ,function() {
                    $(this).removeClass("U-goods-hover").children("div.U-goods-class").hide().prev().find("b").removeClass("b_Triangle")
                }
                ).find("dl").each(function() {
                    $(this).hover(function() {
                    $(this).addClass("U-list-hover")
                }
                ,function() {
                    $(this).removeClass("U-list-hover")
                }
                )});

        });
    </script>
    <script>

function delheader(id){
    var Cartlist = $.cookie('Cartlist');
    var info = $.evalJSON(Cartlist);
    var num=$("#sCartTotal2").html()-1;
    var sum=$("#sCartTotalM").html();
    info['MoenyCount'] = sum-info[id]['money']*info[id]['num'];

    delete info[id];
    //$.cookie('Cartlist','',{path:'/'});
    $.cookie('Cartlist',$.toJSON(info),{expires:30,path:'/'});
    $("#sCartTotalM").html(info['MoenyCount']);
    $('#sCartTotal2').html(num);
    $('#sCartTotal').text(num);
    $('#btnMyCart em').text(num);
    $("#mycartcur"+id).remove();
}
$(function(){
    $(".M-my-1yyg").mouseover(function(){
        $(this).addClass("menu-hd-hover");
    });
    $(".M-shop").mouseover(function(){
        $(this).addClass("menu-hd-hover");
    });
    $(".M-my-1yyg").mouseout(function(){
        $(this).removeClass("menu-hd-hover");
    });
    $(".M-shop").mouseout(function(){
        $(this).removeClass("menu-hd-hover");
    });
});



getAllNum();
</script>

<link rel="stylesheet" href="__CSS__/go/index3.css" />	


<style>
.pic{
	position: relative;
	display: block;
}
.light{
cursor:pointer;
position: absolute;
left: -180px;
top: 0;
width: 200px;
height: 180px;
background-image: -moz-linear-gradient(0deg,rgba(255,255,255,0),rgba(255,255,255,0.5),rgba(255,255,255,0));
background-image: -webkit-linear-gradient(0deg,rgba(255,255,255,0),rgba(255,255,255,0.5),rgba(255,255,255,0));
transform: skewx(-25deg);
-o-transform: skewx(-25deg);
-moz-transform: skewx(-25deg);
-webkit-transform: skewx(-25deg);
}
.pic:hover .light{
	left:180px;
	-moz-transition:0.5s;
	-o-transition:0.5s;
	-webkit-transition:0.5s;
	transition:0.5s;
}
.ulGoodsList a{
    text-decoration: none;
}

</style>



<!--首页打开弹出图-->

<style type="text/css">
    <!--
    html,body {height:100%; margin:0px; font-size:12px;}
    .fixd-index-div {

        z-index:10001;
        width: 500px;
        height: 650px;
        left: 45%;
        top: 10%;
        margin-left:-150px!important;/*FF IE7 该值为本身宽的一半 */
        margin-top:-60px!important;/*FF IE7 该值为本身高的一半*/
        margin-top:0px;
        position:fixed!important;/* FF IE7*/
        position:absolute;/*IE6*/
        _top:       expression(eval(document.compatMode &&
            document.compatMode=='CSS1Compat') ?
            documentElement.scrollTop + (document.documentElement.clientHeight-this.offsetHeight)/2 :/*IE6*/
            document.body.scrollTop + (document.body.clientHeight - this.clientHeight)/2);/*IE5 IE5.5*/

    }


    .bg,.popIframe {
        background-color: #666; display:none;
        width: 100%;
        height: 100%;
        left:0;
        top:0;/*FF IE7*/
        filter:alpha(opacity=50);/*IE*/
        opacity:0.5;/*FF*/
        z-index:1000;
        position:fixed!important;/*FF IE7*/
        position:absolute;/*IE6*/
        _top:       expression(eval(document.compatMode &&
            document.compatMode=='CSS1Compat') ?
            documentElement.scrollTop + (document.documentElement.clientHeight-this.offsetHeight)/2 :/*IE6*/
            document.body.scrollTop + (document.body.clientHeight - this.clientHeight)/2);/* www.codefans.net IE5 IE5.5*/
    }
    .popIframe {
        filter:alpha(opacity=0);/*IE*/
        opacity:0;/*FF*/
    }
    -->
</style>


<div id="popDiv" class="fixd-index-div" style="display:none;">
    <div style="height: 100%">
        <div  href="javascript:closeDiv()" style="background-color: red;height: 100px;width: 100px;position: absolute;right: 0;opacity: 0"></div>
                                                                                                   [Munched]</div>


    <a  style="position: absolute;top: 0;right: 0;opacity: 0;font-size: 25px" href="javascript:closeDiv()">关闭窗口</a></div>
<div id="bg" class="bg" style="display:none;"></div>
<div id='popIframe' class='popIframe' frameborder='0' ></div>

<script language="javascript" type="text/javascript">
    function showDiv(){

        if(localStorage.fixd_index_div!=1){
            $('#popDiv').show("300");
            $('#popIframe').show("300");
            $('#bg').show();
            localStorage.fixd_index_div=1;
        }

    }
    function closeDiv(){
        document.getElementById('popDiv').style.display='none';
        document.getElementById('bg').style.display='none';
        document.getElementById('popIframe').style.display='none';

    }


    $(function(){




        showDiv();
        $('#popIframe').on('click',function(){
            closeDiv()
        })



    })





</script>

<script>
    function newautoScroll(obj){
        // console.log(obj);
        $(obj).find("#topGun").animate({
            marginTop : "-30px"
        },500,function(){
            $(this).css({marginTop : "0px"}).find("li:first").appendTo(this);
        })
    }
    $(function(){
        setInterval('newautoScroll(".swiper_wrap")',3000)
    })
</script>
<style>
    .swiper_wrap{
        overflow:hidden;text-overflow:ellipsis;white-space:nowrap;

    }
    .swiper_wrap ul li{
        list-style: none;
        font-size: 15px;
        font-weight: bold;
        color: #0000FF;
    }

</style>
<!--首页弹出层和滚动-->


<div class="g-wrap w1190">
       <!--最新揭晓-->
            <div class="g-title">
                <h3 class="fl selector">最新揭晓<span></span></h3>
                
                <div class="m-other fr" id="btnMyCart"><a class="goCartList" href="{:U('Home/Yungo/index',array('to'=>1))}" title="云购清单"><em>云购清单</em><span>{$cartNum}</span></a></div>
                <!--
                <div class="swiper_wrap" style="height: 30px;margin-left: 17%">
                    <ul id="topGun">
                        <li>恭喜:135****4524只购买了41.00就获得了百草味&nbsp;2包装  白芝麻猪肉脯180g&nbsp;靖江特产零食小吃</li>
                        <li>恭喜:189****4041只购买了5288.00就获得了Apple&nbsp;iPhone6s&nbsp;16G</li>
                        <li>恭喜:158****0441只购买了5286.00就获得了Apple&nbsp;iPhone6s&nbsp;16G</li>
                        <li>恭喜:189****4041只购买了1.00就获得了Apple&nbsp;iPhone6s&nbsp;16G</li>
                        <li>恭喜:189****4041只购买了1.00就获得了Apple&nbsp;iPhone6s&nbsp;16G</li>
                        <li>恭喜:sasa只购买了1.00就获得了百草味&nbsp;2包装  白芝麻猪肉脯180g&nbsp;靖江特产零食小吃</li>
                        <li>恭喜:sasa只购买了1.00就获得了百草味&nbsp;2包装  白芝麻猪肉脯180g&nbsp;靖江特产零食小吃</li>
                        <li>恭喜:135****4524只购买了1.00就获得了百草味&nbsp;2包装  白芝麻猪肉脯180g&nbsp;靖江特产零食小吃</li>
                        <li>恭喜:135****4524只购买了1.00就获得了百草味&nbsp;2包装  白芝麻猪肉脯180g&nbsp;靖江特产零食小吃</li>
                    </ul>
                </div>
                -->
            </div>
            <div class="g-list">
                <ul id="ulNewAwary">
                	<volist name="newAwary" id="vo">
					<li>
						<dl>
							<dt><a href="{:U('Home/Yungo/index',array('to'=>5,'gid'=>$vo['id']))}" target="_blank" class="pic">
							<img src="__ROOT__/{$vo['thumb']}" alt="{$vo['title']}" height="200px" width="200px">
							<i class="light"></i>
							</a></dt>
						  <dd class="f-gx"><div class="f-gx-user"><span>恭喜</span><span class="blue">{$vo['userName']}</span><span>获得</span></div></dd><br>
							<dd class="u-name"><a href="{:U('Home/Yungo/index',array('to'=>5,'gid'=>$vo['id']))}" target="_blank" class="name">{$vo['title']}</a></dd>
						</dl>
						<cite style="display: inline;"></cite>
					</li>
					</volist>

                </ul>
            </div>
			<script type="text/javascript" src="js/common.js"></script>

            <!--人气商品-->
            <div class="g-title">
				<div class="g-title-main" style="width:950px;float:left;">
                <h3 class="fl selector">人气商品</h3>
                <div class="g-title-more" style="float:right;margin-right:10px;margin-top:13px;"><a href="{:U('Home/Yungo/index',array('to'=>3,'mark'=>4,'msort'=>4))}" target="_blank" title="更多商品，点击查看" class="u-more">更多商品，点击查看>></a></div>
				</div>
				<div style="width:242px;height:30px;background:#DF057D;float:right;margin-top:19px;font-size:16px;margin-right:5px;text-align:center;color:#fff;line-height:30px;letter-spacing:2px;border-top-right-radius:4px;border-top-left-radius:4px;">一元传奇</div>
		   </div>
            <div class="g-hot clrfix">
            	<!--商品列表-->
                <div class="g-hotL fl" id="divHotGoodsList">
                	<volist name="hotGoods" id="vo">
					<div class="g-hotL-list" style="width:236px;">
						<div class="g-hotL-con g-hotL-con-list">
							<ul class="ulGoodsList">
								<li class="g-hot-pic"><a href="{:U('Home/Yungo/index',array('to'=>4,'gid'=>$vo['id']))}" target="_blank" title="{$vo['title']}" class="pic"><img alt="{$vo['title']}" src="__ROOT__/{$vo['thumb']}"><i class="light"></i></a></li>
								<li class="g-hot-name"><a href="{:U('Home/Yungo/index',array('to'=>4,'gid'=>$vo['id']))}" target="_blank" title="{$vo['title']}">{$vo['title']}</a></li>
								<li class="gray">价值：￥{$vo['money']}</li>
								<li class="g-progress"><dl class="m-progress"><dt><b style="width:{$vo['scale']}%;"></b></dt><dd><span class="orange fl"><em>{$vo['canyurenshu']}</em>已参与</span><span class="gray6 fl"><em>{$vo['zongrenshu']}</em>总需人次</span><span class="blue fr"><em>{$vo['zongrenshu']-$vo['canyurenshu']}</em>剩余</span></dd></dl></li>
								<li><a href="javascript:;" class="u-imm nowget" title="只要1元，即可购买" goods_id="{$vo['id']}">立即夺宝</a><a href="javascript:;" title="加入云购清单" class="u-cart oneget" goods_id="{$vo['id']}"><s></s></a></li>
								<div class="Curbor_id" style="display:none;">94</div>
								<div class="Curbor_yunjiage" style="display:none;">1.00</div>
								<div class="Curbor_shenyu" style="display:none;">5288</div>
							</ul>
						</div>
					</div>
					</volist>
				</div>
				<!--传奇列表-->
                <div class="g-hotR fr">
                    <div class="g-zzyging" style="top:10px;">
                        <ul id="UserBuyNewList" style="margin-top: 0px;">
                        	<volist name="newAwary" id = "vo">
							<li><span class="fl"><img alt="{$vo.userName}" width="40" height="40" src="{$vo.userPhoto}"></span><p><em class="blue">{$vo['userName']}</em><br/><PHP>echo date('Y-m-d H:i:s',$vo['q_end_time'])</PHP><br/>
                                购买{$vo['gonumber']}次就获得<a target="_blank" href="#" title="{$vo['title']}" class="u-ongoing">{$vo['title']}</a></p>
                            </li>
                            </volist>
						</ul>
					</div>
					<script>
						function autoScroll(obj){  
							$(obj).find("#UserBuyNewList").animate({  
								marginTop : "-89px"  
							},500,function(){  
								$(this).css({marginTop : "0px"}).find("li:first").appendTo(this);  
							})  
						}  
						$(function(){  
							setInterval('autoScroll(".g-zzyging")',3000)  
						})  
					</script>
                    <div class="u-see100">看一看谁的运气最好！</div>
                </div>
            </div>
			

			<!--商品分类-->
            <volist name="allGoods" id="vo">
			<div class="g-title">
                <h3 class="fl selector">{$key}</h3>
                <div class="g-title-more" style="float:right;margin-right:10px;margin-top:5px;"><a href="{:U('Home/Yungo/index',array('to'=>3,'c1Id'=>$vo[0]['catId']))}" target="_blank" title="更多商品，点击查看" class="u-more">更多商品，点击查看>></a></div>
            </div>

           	<div class="announced-soon clrfix" id="divSoonGoodsList">
           		<!--
            	<div class="g-hotL-list" style="width:236px;">
				<img src="http://lyz.***.com/uploads//admanage/20160121/33211593361448.jpg" alt=""  style="width:236px;height:355px"/>
				</div>			
				--> 
				<volist name="vo" id="vo1">			
				<div class="g-hotL-list">
				<div class="g-hotL-con">
					<ul class="ulGoodsList">
						<li class="g-hot-pic"><a href="{:U('Home/Yungo/index',array('to'=>4,'gid'=>$vo1['id']))}" target="_blank" title="{$vo1['title']}" class="pic"><img alt="{$vo1['title']}" src="__ROOT__/{$vo1['thumb']}"><i class="light"></i></a></li>
						<li class="g-hot-name"><a href="{:U('Home/Yungo/index',array('to'=>4,'gid'=>$vo1['id']))}" target="_blank" title="{$vo1['title']}">{$vo1['title']}</a></li>
						<li class="gray">价值：￥{$vo1['money']}</li>
						<li class="g-progress"><dl class="m-progress"><dt><b style="width:{$vo1['scale']}%;"></b></dt><dd><span class="orange fl"><em>{$vo1['canyurenshu']}</em>已参与</span><span class="gray6 fl"><em>{$vo1['zongrenshu']}</em>总需人次</span><span class="blue fr"><em>{$vo1['zongrenshu']-$vo1['canyurenshu']}</em>剩余</span></dd></dl></li>
						<li><a href="javascript:;" class="u-imm nowget" title="只要1元，即可购买" goods_id="{$vo1['id']}">立即云购</a><a href="javascript:;" title="加入云购清单" class="u-cart oneget" goods_id="{$vo1['id']}"><s></s></a></li>
						<div class="Curbor_id" style="display:none;">21</div>
						<div class="Curbor_yunjiage" style="display:none;">1.00</div>
						<div class="Curbor_shenyu" style="display:none;">799</div>
					</ul>
				</div>
				</div>
				</volist>
			</div>
			</volist>

             <!--最新上架-->
			 <div class="g-title">
                <h3 class="fl selector">最新上架</h3>
				<div class="g-title-more" style="float:right;margin-right:10px;margin-top:5px;"><a href="{:U('Home/Yungo/index',array('to'=>3,'mark'=>1,'msort'=>1))}" target="_blank" title="更多商品，点击查看" class="u-more">更多商品，点击查看>></a></div>
            </div>
			<div class="announced-soon clrfix lastnews_goods" id="divSoonGoodsList" style="width:1190px;">
				<volist name="newGoods" id="vo">
				<dl>
					<dt><a href="{:U('Home/Yungo/index',array('to'=>4,'gid'=>$vo['id']))}" title="{$vo['title']}" target="_blank"><img src="__ROOT__/{$vo['thumb']}" alt="{$vo['title']}"/></a></dt>
					<dd class="goods_name"><p><a href="{:U('Home/Yungo/index',array('to'=>4,'gid'=>$vo['id']))}" title="{$vo['title']}" target="_blank">{$vo['title']}</a></p></dd>
					<dd>总需：{$vo['zongrenshu']}人次</dd>
				</dl>
				</volist>
			</div>
			
			
             <!--晒单分享-->
			<!--
			 <div class="g-title">
                <h3 class="fl selector">晒单分享</h3>
				<div class="g-title-more" style="float:right;margin-right:10px;margin-top:5px;"><a href="http://lyz.***.com/?/go/shaidan/" target="_blank" title="更多晒单，点击查看" class="u-more">更多晒单，点击查看>></a></div>
            </div>
           
            <div class="g-single-sun">
                <div class="singleL fl" id="divPostRec">
									<dl>
						<dt><a href="http://lyz.***.com/?/go/shaidan/detail/2" target="_blank" title="中奖了"><img src="http://lyz.***.com/uploads//shaidan/20160131/62655578209724.png"></a></dt>
						<dd class="u-user">
							<p class="u-head"><a href="http://lyz.***.com/?/uname/99" target="_blank" title="135****4524"><img alt="中奖了" src="http://lyz.***.com/uploads//photo/member.jpg" width="40" height="40"><i></i></a></p>
							<p class="u-info"><span><a href="http://lyz.***.com/?/uname/99" target="_blank" title="135****4524">135****4524</a><em>2016-01-31</em></span><cite><a href="http://lyz.***.com/?/go/shaidan/detail/2" target="_blank" title="中奖了">中奖了</a></cite></p>
						</dd>
						<dd class="m-summary"><cite><a href="http://lyz.***.com/?/go/shaidan/detail/2" target="_blank">哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈哈...</a></cite><b><s></s></b></dd>
					</dl>
				</div>
                <div class="singleR fl">
                    <ul id="ul_PostList">
											<li><a href="http://lyz.***.com/?/go/shaidan/detail/1" target="_blank" title="终于中奖了"><img alt="终于中奖了" src="http://lyz.***.com/uploads//shaidan/20160130/81783181142132.jpg_220270.jpg"><p title="终于中奖了">终于中奖了</p></a></li>
										</ul>
                </div>
            </div>
            -->
			
        </div>
    </div>
	
<script type="text/javascript">
$(function(){
    $("body1").attr('class','index');
	var sw = 0;
	$(".m-slides .rslides_tabs li a").mouseover(function(){
		sw = $(".rslides_tabs a").index(this);
		myShow(sw);
	});
	function myShow(i){
		$(".m-slides .rslides_tabs li").eq(i).addClass("rslides_here").siblings("li").removeClass("rslides_here");
		$("#slideul li").eq(i).stop(true,true).fadeIn(600).siblings("li").fadeOut(600);
	}
	//滑入停止动画，滑出开始动画
	$("#slideImg,.rslides_nav").hover(function(){
		if(myTime){
		   clearInterval(myTime);
		}
	},function(){
		myTime = setInterval(function(){
		  myShow(sw)
		  sw++;
		  if(sw==0){sw=0;}
		} , 3000);
	});
	//自动开始
	var myTime = setInterval(function(){
	   myShow(sw)
	   sw++;
	   if(sw==0){sw=0;}
	} , 3000);
	$(".next").click(function(){
		myShow(sw)
		sw++;
 		if(sw==0){sw=0;}
	});
	$(".pre").click(function(){
		myShow(sw)
 		if(sw==0){sw=0;}
 		sw--;
	});

})
 var l = $("#myTab_Content0");
        $("#myTab").children().each(function(A, z) {
            var B = $(this);
            B.hover(function() {
                if (A == 0) {
                    B.attr("class", "f-notice-hover").next().attr("class", "");
                    l.show().next().hide()
                } else {
                    B.attr("class", "f-notice-hover").prev().attr("class", "");
                    l.hide().next().show()
                }
            }, function() {})
        });
</script>

<script type="text/javascript">
$(document).ready(function(){
	
	var timer = {};

	$('#m_btn').delegate('li', 'mouseenter', function(){
		var self = $(this);
		var tp = self.attr('data-type');
		clearTimeout(timer[tp]);
		timer[tp] = setTimeout(function(){
			self.addClass('text-d-on');
			$('div[data-panel=' + tp + ']').removeClass('hide');
		},100);
	}).delegate('li', 'mouseleave', function(){
		var self = $(this);
		var tp = self.attr('data-type');
		clearTimeout(timer[tp])
		timer[tp] = setTimeout(function(){
			self.removeClass('text-d-on');
			$('div[data-panel=' + tp + ']').addClass('hide');
		},100);
	});
	
	$(document.body).delegate('div.m_content', 'mouseenter', function(){
		clearTimeout(timer[$(this).attr('data-panel')]);
	}).delegate('div.m_content', 'mouseleave', function(){
		$(this).addClass('hide');
		$('span[data-type='+ $(this).attr('data-panel') +']').removeClass('text-d-on');
	});
	
});
</script>
<script type="text/javascript">
$(function(){	
	$(".ulGoodsList a.u-cart").click(function(){
		var sw = $(".ulGoodsList a.u-cart").index(this);
		var src = $(".ulGoodsList .g-hot-pic a img").eq(sw).attr('src');
		var $shadow = $('<img id="cart_dh" style="display:none; border:1px solid #aaa; z-index:99999;" width="200" height="200" src="'+src+'" />').prependTo("body");  			
		var $img = $(".ulGoodsList .g-hot-pic").eq(sw);
		$shadow.css({ 
			'width' : 200, 
			'height': 200, 
			'position' : 'absolute',      
			"left":$img.offset().left+16, 
			"top":$img.offset().top+9,
			'opacity' : 1    
		}).show();
		var $cart = $("#btnMyCart");

		$shadow.animate({   
			width: 1, 
			height: 1, 
			top: $cart.offset().top,    
			left: $cart.offset().left, 
			opacity: 0
		},500,function(){
			Cartcookie(sw,false);
		});	
		
	});
	$(".ulGoodsList a.go_Shopping").click(function(){	
		var sw = $(".ulGoodsList a.go_Shopping").index(this);
		Cartcookie(sw,true); 
	});	
});

//获取COOKIE
var cookie_val = $.cookie('Cartlist');
var len = $.evalJSON(cookie_val);

//存到COOKIE
function Cartcookie(sw,cook){
	var shopid = $(".Curbor_id").eq(sw).text(),	
		shenyu = $(".Curbor_yunjiage").eq(sw).text(),
		money = $(".Curbor_shenyu").eq(sw).text();
	var Cartlist = $.cookie('Cartlist');
	if(!Cartlist){
		var info = {};
	}else{
		var info = $.evalJSON(Cartlist);
	}
	if(!info[shopid]){
		var CartTotal=$("#sCartTotal").text();
			$("#sCartTotal").text(parseInt(CartTotal)+1);
			$("#btnMyCart em").text(parseInt(CartTotal)+1);
	}	
	info[shopid]={}; //用商品ID创建一个新数组
	info[shopid]['num']=1;
	info[shopid]['shenyu']=shenyu;
	info[shopid]['money']=money;
	info['MoenyCount']='0.00';
	$.cookie('Cartlist',$.toJSON(info),{expires:30,path:'/'});
    /*
	if(cook){
		window.location.href="http://lyz.***.com/?/member/cart/cartlist";
	}
    */
}
</script>
<script type="text/javascript">
  function current(){ 
  var d=new Date(),str=''; 
  str +=d.getMonth()+1+'月'; //获取当前月份（0——11） 
  str +=d.getDate()+'日&nbsp;&nbsp;'; 
  str +=d.getHours()+':'; 
  str +=d.getMinutes()+':'; 
  str +=d.getSeconds()+''; 
  return str; } 
  setInterval(function(){$("#nowTime").html(current)},1000); 
</script>
  <style>
  .header-right{float: right;margin-right: 5px;margin-top: 20px;}
  .header-right a{
      display: block;
      width: 130px;text-align: center;
      height: 42px;line-height: 42px;background:#ff4a00;border-radius: 2px;color: #fff;font-size: 20px;
  }
  </style>

	



	



 	<!--end右下角揭晓-->
	<script type="text/javascript">
(function(){				
		var week = '日一二三四五六';
		var innerHtml = '{0}:{1}:{2}';
		var dateHtml = "{0}月{1}日 &nbsp;周{2}";
		var timer = 0;
		var beijingTimeZone = 8;				
				function format(str, json){
					return str.replace(/{(\d)}/g, function(a, key) {
						return json[key];
					});
				}				
				function p(s) {
					return s < 10 ? '0' + s : s;
				}			

				function showTime(time){
					var timeOffset = ((-1 * (new Date()).getTimezoneOffset()) - (beijingTimeZone * 60)) * 60000;
					var now = new Date(time - timeOffset);
					document.getElementById('sp_ServerTime').innerHTML = format(innerHtml, [p(now.getHours()), p(now.getMinutes()), p(now.getSeconds())]);				
					//document.getElementById('date').innerHTML = format(dateHtml, [ p((now.getMonth()+1)), p(now.getDate()), week.charAt(now.getDay())]);
				}				
				
				window.yungou_time = 	function(time){						
					showTime(time);
					timer = setInterval(function(){
						time += 1000;
						showTime(time);
					}, 1000);					
				}
	window.yungou_time(1471330697*1000);
				
})();
				
				
				
$(document).ready(function(){
	try{  
       if(typeof(eval(pleasereg_initx))=="function"){
            pleasereg_initx();
	   }
    }catch(e){
       //alert("not function"); 
    }  
})
</script>
<script>
function delshop(id){
	var Cartlist = $.cookie('Cartlist');
	var info = $.evalJSON(Cartlist);
	var num=$("#rCartTotal2").html()-1;
	var sum=$("#rCartTotalM").html();
	info['MoenyCount'] = sum-info[id]['money']*info[id]['num'];
		
	delete info[id];
	//$.cookie('Cartlist','',{path:'/'});
	$.cookie('Cartlist',$.toJSON(info),{expires:30,path:'/'});
	$("#rCartTotalM").html(info['MoenyCount']);
	$('#rCartTotal2').html(num);
	$('#sCartTotal').text(num);											
	$('#btnMyCart em').text(num);
	$("#shopid"+id).remove();
}
//加入清单
$('.oneget').click(function(){
	var _this = $(this);
	var goods_id = parseInt(_this.attr('goods_id'));
	$.ajax({
		type : 'POST',
		url : '/index.php?m=Go&c=Ajax&a=addShopCart&gid='+goods_id+'&num='+1,
		success : function(res){
			var res = $.parseJSON(res);
			if (res['code'] == 0) {
				if(res['num'] > 0){
			     $('.m-other span').text(res['num']);
				}
			}
		}
	});
});
//立即夺宝
$('.nowget').click(function(){
    var _this = $(this);
    var goods_id = parseInt(_this.attr('goods_id'));
    $.ajax({
        type : 'POST',
        url : '/index.php?m=Go&c=Ajax&a=addShopCart&gid='+goods_id+'&num='+1,
        success : function(res){
            var res = $.parseJSON(res);
            if (res['code'] == 0) {
                if(res['num'] > 0){
                    location.href = "{:U('Home/Yungo/index',array('to'=>1))}"
                }
            }
        }
    });
});
</script>
</block>